﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace _58
{
    class Parttern : Form1
    {
        public static string List_Pattern
        {
            get
            {
                if (FuckSite == 0)
                {
                    return "<dd class=\"w271\">  <a href='(?<url>.*?)' urlparams='(?<psid>.*?)' target=\"_blank\" class=\"fl\".*?title=\".*?\">(?<名称>.*?)</a>      </dd>";
                }
                else
                {
                    return "<a class=\"website fl js_wuba_stas\" target=\"_blank\" href=\"(?<url>.*?)\" data-58stas=\".*?\" gjalog=\".*?\">(?<名称>.*?)</a>";
                }
            }


            set { }
        }
        public static string List_Pattern_ganji { get { return "<a class=\"website fl.*? \" target=\"_blank\" href=\"(?<url>.*?)\" data-58stas=\".*? \" gjalog=\".*? \">(?<名称>.*?)</a>"; } }
        public static string Detial_Parttern { get { return "<li><span>企业网址：</span><a href=\"http://(?<id>.*?).5858.com\" target=\"_blank\" rel=\"nofollow\">.*?</a></li>"; } set { } }
        public static string Conpany_Parttern
        {
            get
            {
                if (FuckSite == 0)
                {
                    return "<li>商家名称：<span>(?<ConpanyName>.*?)</span></li>\\s*<li>联&nbsp;&nbsp;系&nbsp;&nbsp;人：<span>(?<Contacts>.*?)<span[\\s\\S]*<li>联系电话：<span>(?<phone>.*?)</span></li>[\\s\\S]*联系地址：(?<Address>.*?)  联系方式";
                }
                else
                {
                    return "联&ensp;系&ensp;人：</span>[\\s\\S]*?<p class=\"fl\">\\r\\s*(?<Contacts>[\\S]*)[\\S\\s]*?</li>[\\S\\s]*商家地址：[\\S\\s]*</a> (?<Address>.*?)</p></li>[\\S\\s]*联系电话：</span>[\\S\\s]*<p class=\"fl\">\\r\\s*(?<phone>.*?)&nbsp;&nbsp;[\\S\\s]*</p>[\\S\\s]*?</li>[\\S\\s]*?<div id=\"relate-city\">页面简介：.*提供(?<ConpanyName>.*?)联系方式";
                }
            }


            set { }
        }


    }
}
